<include file="public/min-header"/>
<link href="__PUBLIC__/plugins/daterangepicker/daterangepicker-bs3.css" rel="stylesheet" type="text/css" />
<script src="__PUBLIC__/plugins/daterangepicker/moment.min.js" type="text/javascript"></script>
<script src="__PUBLIC__/plugins/daterangepicker/daterangepicker.js" type="text/javascript"></script>

<div class="wrapper">
    <include file="public/breadcrumb"/>
    <section class="content ">
        <!-- Main content -->
        <div class="container-fluid">

            <div class="panel panel-default">
                <div class="panel-body ">   
                    <!--表单数据-->
                    <form method="post" id="handle_shop">

                        <!--通用信息-->
                    <div class="tab-content col-md-10">                 	  
                        <div class="tab-pane active" id="tab_tongyong">                           
                            <table class="table table-bordered">
                                <tbody>

                                <tr>
                                    <td class="col-sm-2">店铺名称：</td>
                                    <td class="col-sm-8">
                                        <input type="text" class="form-control" name="shopName" placeholder="请输入店铺名称">
                                    </td>
                                </tr>

                                <tr>
                                    <td class="col-sm-2">联系电话：</td>
                                    <td class="col-sm-8">
                                        <input type="text" class="form-control" name="shopPhone" placeholder="请输入店铺联系电话">
                                    </td>
                                </tr>

                                <tr>
                                    <td>店铺LOGO：</td>
                                    <td class="col-sm-8">
                                        <div class="col-sm-4">
                                            <input type="text" class="form-control" style="width:350px;margin-left:-15px;" name="shopLogo" id="shopLogo" >
                                        </div>
                                        <div class="col-sm-4">
                                            <input type="button" class="btn btn-default" onClick="GetUploadify(1,'shopLogo','shop','')"  value="上传LOGO图片"/>
                                        </div>
                                    </td>
                                </tr>

                                <tr>
                                    <td>所在省市区:</td>
                                    <td class="col-sm-8">
                                        <div class="col-xs-4">
                                            <select name="shopProvince" id="s_province" class="input-sm" style="width: 170px;"></select>
                                        </div>
                                        <div class="col-xs-4">
                                            <select name="shopCity" id="s_city" class="input-sm" style="width: 170px;"></select>
                                        </div>
                                        <div class="col-xs-4">
                                            <select name="shopArea" id="s_county" class="input-sm" style="width: 170px;"></select>
                                        </div>
                                    </td>
                                </tr>

                                <script src="__PUBLIC__/mingteng/js/area.js"></script>
                                <script type="text/javascript">_init_area();</script>
                                <script type="text/javascript">
                                    var Gid  = document.getElementById ;
                                    var showArea = function(){
                                        Gid('show').innerHTML = "<h3>省" + Gid('s_province').value + " - 市" +
                                            Gid('s_city').value + " - 县/区" +
                                            Gid('s_county').value + "</h3>"
                                    }
                                    Gid('s_county').setAttribute('onchange','showArea()');
                                </script>

                                <tr>
                                    <td>详细地址：</td>
                                    <td class="col-sm-8">
                                        <input type="text" class="form-control" name="shopAddress" placeholder="请输入店铺所在详细地址">
                                    </td>
                                </tr>

                                <tr>
                                    <td>营业时间：</td>
                                    <td class="col-sm-8">
                                        <input type="text" class="form-control" name="shopBusinessTime" placeholder="请输入店铺营业时间，eq：9:00-20:00">
                                    </td>
                                </tr>

                                <tr>
                                    <td>店铺状态：</td>
                                    <td class="col-sm-8">
                                        <input type="radio" class="form-auto" name="shopStatus" value="1" checked="checked" > 开启
                                        <input type="radio" class="form-auto" name="shopStatus" value="0"> 关闭
                                    </td>
                                </tr>


                                </tbody> 
                                <tfoot>
                                	<tr>
                                        <td></td>
                                	    <td class="text-right"><input class="btn btn-primary" type="button" onclick="shop_submit()" value="保存"></td>
                                    </tr>
                                </tfoot>                               
                            </table>
                        </div>                           
                    </div>              
			    	</form><!--表单数据-->
                </div>
            </div>
        </div>
    </section>
</div>
<script>
function shop_submit(){
    ajax_form_submit("handle_shop", "{:url('shop/doAdd')}");
}
</script>
 </body>
 </html>